/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |				
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  8                                   	
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

convertToMeters 0.025;	//This is an scaling operation. Done at the end.

vertices
(
    //block0 vertices
    (-0.25 0.25 0)		//0
    (-0.707106 0.707106 0)	//1
    (0.707106 0.707106 0)	//2
    (0.25 0.25 0)		//3
    (-0.25 0.25 100)		//4
    (-0.707106 0.707106 100)	//5
    (0.707106 0.707106 100)	//6
    (0.25 0.25 100)		//7

    //block1 new vertices
    (0.25 -0.25 0)		//8
    (0.707106 -0.707106 0)	//9
    (0.25 -0.25 100)		//10
    (0.707106 -0.707106 100)	//11

    //block3 new vertices
    (-0.25 -0.25 0)		//12
    (-0.707106 -0.707106 0)	//13
    (-0.25 -0.25 100)		//14
    (-0.707106 -0.707106 100)	//15
);

xcells 20;
ycells 40;
zcells 60;

xcells1 20;
ycells1 20;
zcells1 60;

stretch 0.25;

blocks
(
    //block0
    hex (0 3 2 1 4 7 6 5) 	($xcells $ycells $zcells) simpleGrading (1 $stretch 1)
    //block1
    hex (3 8 9 2 7 10 11 6) 	($xcells $ycells $zcells) simpleGrading (1 $stretch 1)
    //block2
    hex (8 12 13 9 10 14 15 11) ($xcells $ycells $zcells) simpleGrading (1 $stretch 1)
    //block3
    hex (12 0 1 13 14 4 5 15) 	($xcells $ycells $zcells) simpleGrading (1 $stretch 1)
    //block4
    hex (0 12 8 3 4 14 10 7) 	($xcells1 $ycells1 $zcells1) simpleGrading (1 1 1)
);

edges
(
    //block0 arc
    arc 1 2  (0 1 0)
    arc 5 6  (0 1 100)

    //block1 arc
    arc 2 9  (1 0 0)
    arc 6 11 (1 0 100)

    //block2 arc
    arc 9 13  (0 -1 0)
    arc 11 15 (0 -1 100)

    //block3 arc
    arc 1 13  (-1 0 0)
    arc 5 15  (-1 0 100)
);

boundary
(

    inlet
    {
        type patch;
        faces
        (
            (0 1 2 3)
            (2 3 8 9)
            (8 9 13 12)
            (13 12 0 1)
            (0 3 8 12)
        );
    }

    outlet
    {
        type patch;
        faces
        (
            (4 5 6 7)
            (6 7 10 11)
            (15 11 10 14)
            (15 14 4 5)
            (4 7 10 14)
        );
    }

    pipe
    {
        type wall;
        faces
        (
            (1 5 6 2)
            (2 6 11 9)
            (9 11 15 13)
            (15 13 5 1)
        );
    }

);

mergePatchPairs
(
);

// ************************************************************************* //
